without using discriminant solve euuation